@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

.hero {
  padding: 2rem 1rem;
  margin-bottom: 2rem;
  overflow: hidden;
  text-align: center;

  &Title {
    margin-bottom: 1rem;
    font-size: 2.5rem;
    color: var(--text-primary);
    opacity: 0;
    animation: fade-in-up 0.8s ease-out forwards;
    animation-delay: 0.2s;
  }

  &Description {
    max-width: 800px;
    margin: 0 auto 2rem;
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--text-secondary);
    opacity: 0;
    animation: fade-in-up 0.8s ease-out forwards;
    animation-delay: 0.4s;
  }

  &Cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 2rem;
    opacity: 0;
    animation: fade-in-up 0.8s ease-out forwards;
    animation-delay: 0.6s;
  }

  &TechStack {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
    margin-top: 3rem;
    opacity: 0;
    animation: fade-in-up 0.8s ease-out forwards;
    animation-delay: 0.8s;
  }

  &TechStack img {
    width: auto;
    height: 40px;
    opacity: 0.8;
    transition: all 0.3s ease;
    animation: float 3s ease-in-out infinite;
    animation-delay: calc(0.5s * var(--i));

    &:hover {
      opacity: 1;
      transform: translateY(-5px);
    }
  }
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  border-radius: 4px;
  transition: all 0.3s ease;

  &Primary {
    color: white;
    background: var(--primary-color);
    transform: translateY(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    &:hover {
      background: var(--primary-dark);
      box-shadow: 0 10px 20px rgb(0 0 0 / 10%);
      transform: translateY(-3px);
    }

    &:active {
      transform: translateY(1px);
    }
  }

  &Secondary {
    color: var(--primary-color);
    background: transparent;
    border: 2px solid var(--primary-color);
    transform: translateY(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    &:hover {
      background: rgb(var(--primary-rgb) / 10%);
      box-shadow: 0 10px 20px rgb(0 0 0 / 10%);
      transform: translateY(-3px);
    }

    &:active {
      transform: translateY(1px);
    }
  }

  a {
    color: white;
    text-decoration: none;
  }
}

@media (width <= 768px) {
  .hero {
    padding: 3rem 1rem;

    &Title {
      font-size: 2rem;
    }

    &TechStack {
      gap: 1.5rem;

      img {
        animation: none;
      }
    }

    &Description {
      font-size: 1.1rem;
    }
  }
}
